<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>

    <script>
        // 将proto对象设为obj对象的原型，所以从obj对象可以读取proto对象的属性
        let proto = {};
        let obj = {x: 10};
        Object.setPrototypeOf(obj, proto);

        proto.y = 20;
        proto.z = 40;

        console.log(obj);

    </script>

</head>
<body>

</body>
</html>